package com.panfeng.xcloud.boss.provider.member.dto.request;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;
import java.io.Serializable;

@Data
@ApiModel(value = "用户注册请求")
public class RegReqDTO implements Serializable {

    @NotBlank(message = "用户类型不能为空")
    @ApiModelProperty("用户类型 C/B")
    private String userType;

    /*@NotBlank(message = "手机号或邮箱不能为空")
    @ApiModelProperty("手机号或邮箱")
    private String account;*/

    @NotBlank(message = "用户名不能为空")
    @ApiModelProperty("用户名")
    private String nickname;

    @NotBlank(message = "邀请码不能为空")
    @ApiModelProperty("邀请码")
    private String inviteCode;

    @Pattern(regexp = "^(?=.*[a-zA-Z])(?=.*\\d)[a-zA-Z\\d]{6,20}$", message = "登录密码格式不正确，设置6-20位字母与数字的组合")
    @ApiModelProperty("登录密码")
    private String password;

   /* @NotBlank(message = "验证码不能为空")
    @ApiModelProperty("验证码")
    private String verifyCode;*/

    @ApiModelProperty("是否接受协议 0 接受 1 不接受")
    private Integer acceptAgreement;

}
